// 拍摄后马上可以测试的图片
let testArr = []
// for (let index = 321; index <= 361; index++) {
//   const element = index > 99 ? `0${index}` : `00${index}`
//   if([333,317].indexOf(index)==-1) testArr.push(element)
// }
for (let index = 540; index <= 548; index++) {
  const element = index > 99 ? `0${index}` : `00${index}`
  // if(![542,543,547].indexOf(index)==-1) testArr.push(element)
  testArr.push(element)
}
for (let index = 566; index <= 834; index++) {
  const element = index > 99 ? `0${index}` : `00${index}`
  testArr.push(element)
}
const getAvatarUrl = (index) => {
  if(index){
    try {
      return require(`@/assets/cb/GS__${index}.jpg`)
    } catch(e) {
      // 如果图片不存在就返回空
      return ''
    }
  }
  return ''
}
let VRTreeAll = [
  {
    id: '0',
    pid: null,
    title: "全部分类",
    type: 1,
    sceneList: [],
    thumbUrl: "",
    status: 1,
    children: [ 
      {
        id: '1',
        pid: '0',
        title: "1楼",
        type: 1,
        sceneList: testArr.map((item, index) => {
          let val = getAvatarUrl(item)
          return { 
            pid: '1',
            id:'a' + index,
            type: 2, 
            title: `${val.split('/')[2]}`,
            description: '',
            status: 1,
            thumbUrl: val, //封面图
            logo: '', //场景logo
            VRImg: val, //VR图
            publishTime: '2023-12-07 18:26:55',
            author: 'lbw',
            bgsound: '', //背景音乐
            markerList: [],
            isFirst: true,
          }
        }).filter(item=>item.VRImg),
        thumbUrl: "",
        status: 1,
        children: []
      }
    ]
  },
]

export {VRTreeAll}